﻿@* Licensed to the Chroma Control Contributors under one or more agreements. *@
@* The Chroma Control Contributors licenses this file to you under the MIT license. *@
@* See the LICENSE file in the project root for more information. *@

<div class="window-controls">
    <button class="window-control" type="button" tabindex="-1" aria-label="Minimize" aria-hidden="true" @onclick="OnMinimize">
        <svg aria-hidden="true" version="1.1" width="10" height="10">
            <path d="M 0,5 10,5 10,6 0,6 Z"></path>
        </svg>
    </button>
    @if (Window.WindowState == WindowState.Maximized)
    {
        <button class="window-control" type="button" tabindex="-1" aria-label="Restore" aria-hidden="true" @onclick="OnRestore">
            <svg aria-hidden="true" version="1.1" width="10" height="10">
                <path d="m 2,1e-5 0,2 -2,0 0,8 8,0 0,-2 2,0 0,-8 z m 1,1 6,0 0,6 -1,0 0,-5 -5,0 z m -2,2 6,0 0,6 -6,0 z"></path>
            </svg>
        </button>
    }
    else
    {
        <button class="window-control" type="button" tabindex="-1" aria-label="Maximize" aria-hidden="true" @onclick="OnMaximize">
            <svg aria-hidden="true" version="1.1" width="10" height="10">
                <path d="M 0,0 0,10 10,10 10,0 Z M 1,1 9,1 9,9 1,9 Z"></path>
            </svg>
        </button>
    }
    <button class="window-control" type="button" tabindex="-1" aria-label="Close" aria-hidden="true" @onclick="OnClose">
        <svg aria-hidden="true" version="1.1" width="10" height="10">
            <path d="M 0,0 0,0.7 4.3,5 0,9.3 0,10 0.7,10 5,5.7 9.3,10 10,10 10,9.3 5.7,5 10,0.7 10,0 9.3,0 5,4.3 0.7,0 Z"></path>
        </svg>
    </button>
</div>
